package com.diankangwo.factory.dao;

import com.diankangwo.factory.entity.TdSpecies;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;
@Mapper
@Repository
public interface TdSpeciesMapper {


    int deleteByPrimaryKey(Integer id);

    int insert(TdSpecies record);

    int insertSelective(TdSpecies record);

    TdSpecies selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(TdSpecies record);

    int updateByPrimaryKey(TdSpecies record);

    /**
     * 查询所有三级分类
     * @return
     */
    List<TdSpecies> queryAll();

    /**
     * 根据二级分类获取所有三级分类
     * @param claId
     * @return
     */
    List<TdSpecies> queryByClaId(int claId);


    /**
     * 批量删除
     */
    void deleteBatch(int claId);
}